{include file="inc/header_index_mui.html"}
<link href="css/mui.min.css" rel="stylesheet" />
<link rel="stylesheet" href="css/aui.css" />
<script src="js/jquery-1.8.2.min.js"></script>
<style>
	input::-webkit-input-placeholder {
		font-size: 14px;
		color: #ddd;
		padding-left: 15px;
	}
</style>

<script src="js-yuan/jquery.timer.js"></script>
<script src="js-yuan/sms_verify.js"></script>
<link rel="stylesheet" href="css-yuan/style.css" />




<div class="mui-content aui-mar-t-15 ">
<form action="{url x="index" r="user#dophregister"}" id="register_box">
	<div class="mui-row aui-mar-t-15 ">
		<div class="mui-col-xs-3 mui-col-xs-3"></div>
		<div class="mui-col-xs-6 mui-col-xs-6 mui-text-center">
			<img class="aui-col-5" src="image/logo.png" alt="" />
			<input type="hidden" name="user_logo" id="user_logo" value="/wap/image/logo.png" />
		</div>
		<div class="mui-col-xs-3 mui-col-xs-3"></div>
	</div>
	<div class="mui-row aui-mar-t-15 ">
		<div class="mui-col-xs-3 mui-col-xs-3"></div>
		<div class="mui-col-xs-6 mui-col-xs-6 mui-text-center">
			<div class="mui-input-row mui-radio mui-left">
				<label>	<img class=" aui-col-8 re rebom	" src="image/boy.png" alt="" /></label>
				<input name="sex" type="radio" value=1 checked />
			</div>
		
			<div class="mui-input-row mui-radio mui-left">
				<label><img class=" aui-col-8 re rebom	" src="image/girl.png" alt="" /></label>
				<input name="sex" type="radio" value=0 />
			</div>
			

		</div>
		<div class="mui-col-xs-3 mui-col-xs-3"></div>
	</div>
	<div id='login-form' class=" mui-input-group aui-mar-t-10">
		<div class=" mui-input-row">
			<label><p class="aui-color-c">江湖昵称</p></label>
			<input class="aui-col-8" name="user_name" id="user_name" type="text"  class="mui-input-clear mui-input" placeholder="">
		</div>

	</div>
	<div id='login-form' class=" mui-input-group aui-mar-t-10">
		<div class=" mui-input-row">
			<label><p class="aui-color-c">手机号</p></label>
			<input class="aui-col-8" name="mobile" id="mobile" type="text" class="mui-input-clear mui-input" placeholder="">
		</div>

	</div>

	<div id='login-form' class="mui-input-group aui-mar-t-10">

		<div class="mui-input-row">
			<button type="button" class="mui-btn mui-btn-primary" id="sms_btn" unique="1" lesstime="{$sms_lesstime}">发送验证码</button>
			<label><p  class="aui-color-c">输入验证码</p></label>
			<input id = "sms_verify" name="sms_verify" style="width:35%" id='password' type="text" class="mui-input-clear mui-input" placeholder="">

		</div>
	</div>
	<div id='login-form' class="mui-input-group aui-mar-t-10">
		<div class="mui-input-row">
			<label><p class="aui-color-c">设置密码</p></label>
			<input id='password' name="user_pwd" type="password" class="mui-input-clear mui-input" placeholder="">
		</div>
	</div>

	<div class="mui-row mui-text-center aui-mar-t-15">
		<a href="#"><button id="queding" type="button" class="mui-btn mui-btn-primary aui-col-5" onclick="$('#register_box').submit();">确认</button></a>
	</div>
</form>
</div>

{include file="inc/sms_verify_code.html"}
<script>
$("#register_box").bind("submit",function(){

	var user_name = $.trim($(this).find("input[name='user_name']").val());
	var mobile = $.trim($(this).find("input[name='mobile']").val());
	var mobile = $.trim($(this).find("input[name='mobile']").val());
	var user_pwd = $.trim($(this).find("input[name='user_pwd']").val());
	var sms_verify = $.trim($(this).find("input[name='sms_verify']").val());
	if(user_name=="")
	{
		alert("请输入江湖昵称");
		return false;
	}
	if(mobile=="")
	{
		alert("请输入手机号");
		return false;
	}
	if(mobile.length<11)
	{
		alert("手机号格式错误");
		return false;
	}
	if(sms_verify=="")
	{
		alert("请输入短信验证码");
		return false;
	}
	if(user_pwd=="")
	{
		alert("请输入密码");
		return false;
	}
	if(user_pwd.length<4)
	{
		alert("密码长度不符");
		return false;
	}
	var query = $(this).serialize();
	var ajax_url = $(this).attr("action");
	if(!is_lock){
		is_lock=true;

		$.ajax({
			url:ajax_url,
			data:query,
			type:"POST",
			dataType:"json",
			success:function(obj){
				if(obj.status)
				{
					alert(obj.info);
					location.href = obj.jump;				
				}
				else
				{
					alert(obj.info);
					is_lock=false;
				}
			}
		});
		return false;
	}
});

var is_lock=false;
</script>
<?php
/*
$this->_var['pagecss'][] = $this->_var['TMPL_REAL']."/css/public.css";
$this->_var['pagecss'][] = $this->_var['TMPL_REAL']."/css/style.css";
$this->_var['pagecss'][] = $this->_var['TMPL_REAL']."/css/user_login.css";

$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery-1.6.2.min.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery.bgiframe.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery.timer.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery.weebox.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/jquery.touchwipe.js";
$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/utils/fastclick.js";

$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/fanwe_utils/fanweUI.js";
$this->_var['cpagejs'][] = $this->_var['TMPL_REAL']."/js/fanwe_utils/fanweUI.js";

$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/script.js";
$this->_var['cpagejs'][] = $this->_var['TMPL_REAL']."/js/script.js";

$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/user_register.js";
$this->_var['cpagejs'][] = $this->_var['TMPL_REAL']."/js/user_register.js";

$this->_var['pagejs'][] = $this->_var['TMPL_REAL']."/js/sms_verify.js";
$this->_var['cpagejs'][] = $this->_var['TMPL_REAL']."/js/sms_verify.js";

?>
{include file="inc/header_register.html"}

<div class="wrap">
	<form action="{url x="index" r="user#dophregister"}" id="register_box">
	<section class="register">
		<ul class="input-list split-line-top split-line">
			<li>
				<i class="iconfont">&#xe6eb;</i>
				<div class="input-box split-line">
				<label class="com-input">
					<input class="phone-num"  type="tel" maxlength="11" class="mobile" name="mobile" id="mobile" placeholder="请输入手机号" placeholder="请输入您的手机号码">
				</label>
				<label>
					<input class="btn_phone" type="Button"  id="sms_btn" unique="1" value="点击获取验证码" lesstime="{$sms_lesstime}" />
				</label>
				</div>
			</li>
			<li>
				<i class="iconfont">&#xe6f0;</i>
				<div class="input-box split-line">
				<label class="com-input">
                                    <input class="testing third" maxlength="6" type="tel" id = "sms_verify" name="sms_verify"  placeholder="请输入手机短信中的验证码" style="width:80%">
				</label>
				
				</div>
			</li>
			<li>
				<i class="iconfont">&#xe6ef;</i>
				<div class="input-box split-line">
				<label class="com-input">
					<input type="password" name="user_pwd" placeholder="请输入您的登录密码" class="password">
				</label>
				</div>
			</li>

		</ul>
		<div class="login-btn-box">
		<input type="submit" value="完成注册" class="login-btn login-btn-red">
		</div>
		<div class="a-box">
		<a href="{url x="index" r="user#getpassword"}" class="forget fr">忘记密码？</a>
		<div class="clear"></div>
		</div>
	</section>
</form>
</div>
{include file="inc/sms_verify_code.html"}
{include file="inc/footer_index.html"}